<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Template With If Statement</title>
</head>
<body>
    <div>
        {% if user %}
            <h1>Hello, {{ user }}!</h1>
        {% else %}
            <h1>Hello, Stranger!</h1>
        {% endif %}
    </div>
</body>
</html>